import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter);

import index from '../components/index.vue'
import hello from '../components/HelloWorld.vue'
//const index    = (resolve) => require(['./page/index.vue'],resolve)

//路由指向
const routes = [
    { path: '/', component: index },
    { path: '/hello', component: hello },
];
export default new VueRouter({
    routes: routes,
    mode: 'history',
    // mode: 'hash',
    // base: __dirname
})
